package cn.kailangtu.myapplication.broadcast;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

import cn.kailangtu.myapplication.MainActivity;


public class BootCompletedReceiver extends BroadcastReceiver {

    @Override
    public void onReceive(Context context, Intent intent) {
        String action = intent.getAction();
        if (action.equals(Intent.ACTION_BOOT_COMPLETED)) {
            Intent intent2 = new Intent(context, MainActivity.class);
            context.startActivity(intent2);
        }
    }
}
